//
//  CustomButton.h
//  练习_11.03_1
//
//  Created by rimi1 on 2016/11/3.
//  Copyright © 2016年 Wangxingqian. All rights reserved.
//

#import <UIKit/UIKit.h>

typedef NS_ENUM(NSInteger, WXQButtonImageLocation) {
    WXQImageLocationLeft = 0,
    WXQImageLocationTop,
    WXQImageLocationRight,
    WXQImageLocationBottom,
};

@interface WXQButton : UIControl

@property (nonatomic, strong, readonly) UIImageView *wBackImageView;
@property (nonatomic, strong, readonly) UIImageView *wImageView;
@property (nonatomic, strong, readonly) UILabel *wTitle;

@property (nonatomic, assign) BOOL wSelect;
@property (nonatomic, assign, readonly) UIControlState wStatus;
@property (nonatomic, assign) WXQButtonImageLocation imageLocation;// 默认 WXQImageLocationLeft

- (instancetype)initWithFrame:(CGRect)frame
                        title:(NSString *)title
                   titleColor:(UIColor *)titleColor
                    imageName:(NSString *)imageName
                imageLocation:(WXQButtonImageLocation)imageLocation;

- (void)setBackImage:(UIImage *)backImage forState:(UIControlState)state;
- (void)setTitle:(NSString *)title forState:(UIControlState)state;
- (void)setTitleColor:(UIColor *)titleColor forState:(UIControlState)state;
- (void)setImage:(UIImage *)image forState:(UIControlState)state;

@end











